export default {
  totalMoney (state) {
    return state.cart.reduce((sum, shop) => {
      if (shop.check) {
        sum = sum + shop.count * shop.price * 100
      }
      return sum
    }, 0)
  },
  isAllCheck (state) {
    return state.cart.every(shop => {
      return shop.check
    })
  }
}
